package com.zx.service;

import com.zx.bean.Firm;
import com.zx.bean.Manager;
import com.zx.mapper.ManagerMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ManagerService {
    @Autowired
    private ManagerMapper managerMapper;

    //添加管理员
    public int addManager(Manager manager){
        return managerMapper.addManager(manager);
    }

    //删除
    public int delManager(int id){
        return managerMapper.delManager(id);
    }
    //修改
    public Manager updateManager(int id){
        return managerMapper.updateManager(id);
    }
    //查询单个
    public Manager findOneManager(int id){
        return managerMapper.findOneManager(id);
    }
    //查询全部
    public List<Manager> findAllManager(){
        return managerMapper.findAllManager();
    }
}
